<template>
    <el-table :data="tableData" style="width: 100%">
        <el-table-column type="index" label="序号" width="100" />

        <el-table-column prop="finishedName" label="名称" width="120" />
        <el-table-column prop="finishedCode" label="编号" width="120" />
        <el-table-column prop="finishedThrough" label="状态" width="120" />
        <el-table-column prop="finishedSum" label="数量" width="120" />
        <el-table-column prop="finishedUnit" label="单位" width="120" />
        <el-table-column prop="addProp" label="操作人" width="120" />
        <el-table-column prop="addTime" label="添加时间" width="200">
            <template #default="script">
                {{ moment(script.row.addTime).format("YYYY-MM-DD HH:mm:ss") }}
            </template>
        </el-table-column>
        <el-table-column prop="updTime" label="修改时间" width="200">
            <template #default="script">
                {{ moment(script.row.updTime).format("YYYY-MM-DD HH:mm:ss") }}
            </template>
        </el-table-column>


        <el-table-column fixed="right" label="Operations" min-width="120">
            <template #default>
                <el-button link type="primary" size="small" @click="">
                    Detail
                </el-button>
                <el-button link type="primary" size="small">Edit</el-button>
            </template>
        </el-table-column>
    </el-table>
</template>

<script lang="ts" setup>
import { ref, reactive, onMounted } from 'vue'
import Mesaxios from '../../Http/MesHelp'
import moment from 'moment';

const tableData = ref([])

const WareMaterialShow = () => {
    Mesaxios.get("/api/Storehouse/FinishedShow").then(res => {
        tableData.value = res.data.data.list
        console.log(tableData.value)
    })
}

onMounted(() => {
    WareMaterialShow()
})

</script>
